using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Star : MonoBehaviour
{
    private void OnTriggerEnter2D(Collider2D collision)
    {
        if (collision.CompareTag("Candy"))
        {
            Debug.Log("OnTriggerEnter2D");
            GameManager.instance.StarCount++;
            gameObject.SetActive(false);
            Destroy(gameObject);
        }
    }
}
